DisCSP.CSPLexerParser
Class Token

java.lang.Object
  extended byDisCSP.CSPLexerParser.Token

public class Token
extends java.lang.Object


Field Summary
(package private)  char charValue
           
(package private)  int intValue
           
(package private)  boolean isCh
           
(package private)  boolean isEnd
           
(package private)  boolean isEol
           
(package private)  boolean isInt
           
(package private)  boolean isStr
           
(package private)  java.lang.String strValue
           
 
Constructor Summary
Token(int t, double nval, int ttype, java.lang.String sval)
          Costruttore di Token
 
Method Summary
 char getChar()
          Getter di charValue
 int getInt()
          Getter di doubleValue
 java.lang.String getString()
          Getter di strValue
 boolean isChar()
          Getter di isCh
 boolean isEnd()
           
 boolean isEOL()
           
 boolean isInt()
          Getter di isDb
 boolean isString()
          Getter di isStr
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

isInt

boolean isInt

isEnd

boolean isEnd

isEol

boolean isEol

isCh

boolean isCh

isStr

boolean isStr

intValue

int intValue

charValue

char charValue

strValue

java.lang.String strValue
Constructor Detail

Token

public Token(int t,
             double nval,
             int ttype,
             java.lang.String sval)
Costruttore di Token

Parameters:
t - indica il tipo di token letto dallo StreamTokenizer
nval - il numero eventualmente letto dallo StreamTokenizer
ttype - il carattere eventualmente letto dallo StreamTokenizer
sval - la stringa eventualmente letta dallo StreamTokenizer
Method Detail

isInt

public boolean isInt()
Getter di isDb

Returns:
true se il token corrente è un double

isEnd

public boolean isEnd()

isEOL

public boolean isEOL()

isChar

public boolean isChar()
Getter di isCh

Returns:
true se il token corrente è un carattere

isString

public boolean isString()
Getter di isStr

Returns:
true se il token corrente è unaStringa

getInt

public int getInt()
           throws LexerException
Getter di doubleValue

Returns:
se il token corrente è un double lo restituisce
Throws:
LexerException

getChar

public char getChar()
             throws LexerException
Getter di charValue

Returns:
se il token corrente è un char lo restituisce
Throws:
LexerException

getString

public java.lang.String getString()
                           throws LexerException
Getter di strValue

Returns:
se il token corrente è una stringa la restituisce
Throws:
LexerException